/*
 * Copyright 2010 bedatadriven
 *
 *    Licensed under the Apache License, Version 2.0 (the "License");
 *    you may not use this file except in compliance with the License.
 *    You may obtain a copy of the License at
 *
 *        http://www.apache.org/licenses/LICENSE-2.0
 *
 *    Unless required by applicable law or agreed to in writing, software
 *    distributed under the License is distributed on an "AS IS" BASIS,
 *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *    See the License for the specific language governing permissions and
 *    limitations under the License.
 */

/**
 * JacobGen generated file --- do not edit
 *
 * (http://www.bigatti.it/projects/jacobgen)
 */
package com.bedatadriven.mso.powerpoint;

import com.bedatadriven.mso.core.MsoLanguageID;
import com.bedatadriven.mso.core.MsoTriState;
import com.google.gwt.core.client.JavaScriptObject;

/** Wrapper for PowerPoint.TextRange*/
public class TextRange extends JavaScriptObject {

	protected TextRange() { }
	public native final JavaScriptObject get_NewEnum()/*-{
		return this._NewEnum;
	}-*/;

	public native final JavaScriptObject _Index(int index)/*-{
		return this._Index( index);
	}-*/;

	public native final int getCount()/*-{
		return this.Count;
	}-*/;

	public native final PpApplication getApplication()/*-{
		return this.Application;
	}-*/;

	public native final Object getParent()/*-{
		return this.Parent;
	}-*/;

	public native final ActionSettings getActionSettings()/*-{
		return this.ActionSettings;
	}-*/;

	public native final int getStart()/*-{
		return this.Start;
	}-*/;

	public native final int getLength()/*-{
		return this.Length;
	}-*/;

	public native final float getBoundLeft()/*-{
		return this.BoundLeft;
	}-*/;

	public native final float getBoundTop()/*-{
		return this.BoundTop;
	}-*/;

	public native final float getBoundWidth()/*-{
		return this.BoundWidth;
	}-*/;

	public native final float getBoundHeight()/*-{
		return this.BoundHeight;
	}-*/;

	public native final TextRange paragraphs(int start, int length)/*-{
		return this.Paragraphs( start, length);
	}-*/;

	public native final TextRange sentences(int start, int length)/*-{
		return this.Sentences( start, length);
	}-*/;

	public native final TextRange words(int start, int length)/*-{
		return this.Words( start, length);
	}-*/;

	public native final TextRange characters(int start, int length)/*-{
		return this.Characters( start, length);
	}-*/;

	public native final TextRange lines(int start, int length)/*-{
		return this.Lines( start, length);
	}-*/;

	public native final TextRange runs(int start, int length)/*-{
		return this.Runs( start, length);
	}-*/;

	public native final TextRange trimText()/*-{
		return this.TrimText( );
	}-*/;

	public native final String getText()/*-{
		return this.Text;
	}-*/;

	public native final void setText(String value)/*-{
		this.Text = value;
	}-*/;

	public native final TextRange insertAfter(String newText)/*-{
		return this.InsertAfter( newText);
	}-*/;

	public native final TextRange insertBefore(String newText)/*-{
		return this.InsertBefore( newText);
	}-*/;

	protected native final TextRange _insertDateTime(int dateTimeFormat,  int insertAsField)/*-{
		return this.InsertDateTime( dateTimeFormat, insertAsField);
	}-*/;

	public final TextRange insertDateTime(int dateTimeFormat, MsoTriState insertAsField){
		return _insertDateTime(dateTimeFormat, insertAsField.getValue());
	}
	public native final TextRange insertSlideNumber()/*-{
		return this.InsertSlideNumber( );
	}-*/;

	protected native final TextRange _insertSymbol(String fontName, int charNumber,  int unicode)/*-{
		return this.InsertSymbol( fontName, charNumber, unicode);
	}-*/;

	public final TextRange insertSymbol(String fontName, int charNumber, MsoTriState unicode){
		return _insertSymbol(fontName, charNumber, unicode.getValue());
	}
	public native final Font getFont()/*-{
		return this.Font;
	}-*/;

	public native final ParagraphFormat getParagraphFormat()/*-{
		return this.ParagraphFormat;
	}-*/;

	public native final int getIndentLevel()/*-{
		return this.IndentLevel;
	}-*/;

	public native final void setIndentLevel(int value)/*-{
		this.IndentLevel = value;
	}-*/;

	public native final void select()/*-{
		this.Select( );
	}-*/;

	public native final void cut()/*-{
		this.Cut( );
	}-*/;

	public native final void copy()/*-{
		this.Copy( );
	}-*/;

	public native final void delete()/*-{
		this.Delete( );
	}-*/;

	public native final TextRange paste()/*-{
		return this.Paste( );
	}-*/;

	public native final void changeCase(int type)/*-{
		this.ChangeCase( type);
	}-*/;

	public native final void addPeriods()/*-{
		this.AddPeriods( );
	}-*/;

	public native final void removePeriods()/*-{
		this.RemovePeriods( );
	}-*/;

	protected native final TextRange _find(String findWhat, int after,  int matchCase,  int wholeWords)/*-{
		return this.Find( findWhat, after, matchCase, wholeWords);
	}-*/;

	public final TextRange find(String findWhat, int after, MsoTriState matchCase, MsoTriState wholeWords){
		return _find(findWhat, after, matchCase.getValue(), wholeWords.getValue());
	}
	protected native final TextRange _replace(String findWhat, String replaceWhat, int after,  int matchCase,  int wholeWords)/*-{
		return this.Replace( findWhat, replaceWhat, after, matchCase, wholeWords);
	}-*/;

	public final TextRange replace(String findWhat, String replaceWhat, int after, MsoTriState matchCase, MsoTriState wholeWords){
		return _replace(findWhat, replaceWhat, after, matchCase.getValue(), wholeWords.getValue());
	}
	public native final void rotatedBounds(float x1, float y1, float x2, float y2, float x3, float y3, float x4, float y4)/*-{
		this.RotatedBounds( x1, y1, x2, y2, x3, y3, x4, y4);
	}-*/;

	protected native final int _getLanguageID()/*-{
		return this.LanguageID;
	}-*/;

	public final MsoLanguageID getLanguageID(){
		return MsoLanguageID.valueOf(_getLanguageID());
	}
	protected native final void _setLanguageID( int value)/*-{
		this.LanguageID = value;
	}-*/;

	public final void setLanguageID(MsoLanguageID value){
		_setLanguageID(value.getValue());
	}
	public native final void rtlRun()/*-{
		this.RtlRun( );
	}-*/;

	public native final void ltrRun()/*-{
		this.LtrRun( );
	}-*/;

	protected native final TextRange _pasteSpecial(int dataType,  int displayAsIcon, String iconFileName, int iconIndex, String iconLabel,  int link)/*-{
		return this.PasteSpecial( dataType, displayAsIcon, iconFileName, iconIndex, iconLabel, link);
	}-*/;

	public final TextRange pasteSpecial(int dataType, MsoTriState displayAsIcon, String iconFileName, int iconIndex, String iconLabel, MsoTriState link){
		return _pasteSpecial(dataType, displayAsIcon.getValue(), iconFileName, iconIndex, iconLabel, link.getValue());
	}
}
